package com.yuke.cloud.service.smc.service;

import com.github.pagehelper.PageInfo;
import com.yuke.cloud.service.api.pmc.dto.ProdCategoryDto;
import com.yuke.cloud.service.api.smc.dto.GoodsAndSpecInfoDto;
import com.yuke.cloud.service.api.smc.dto.ShopGoodsSalePriceDto;
import com.yuke.cloud.service.smc.dto.*;
import com.yuke.cloud.service.smc.entity.ShopGoods;
import com.yuke.cloud.common.core.support.IService;
import io.swagger.models.auth.In;

import java.util.List;


/**
 * Created by wg on 2018/09/10.
 */
public interface ShopGoodsService extends IService<ShopGoods> {
    void applyGoods(Long shopId, Long specId);
    void updateGoodsPrice(Long shopGoodsId,Integer salePrice);
    void goodsIsAlive(String shopGoodsIds, Integer isAlive);
    List<ShopGoods> getListByCondition(ShopGoods shopGoods);

    List<ShopAndGoodsInfoDto> getShopAndGoodsBySpecId(Long specId, String longitude, String latitude, Long userId);
    ShopGoodsInfoDto getShopGoodsInfoByShopId(Long shopId);
    List<ProdCategoryDto> getShopCategoryIsAliveByShopId(Long shopId);
    List<ProdCategoryDto> getShopCategoryAllByShopId(Long shopId);
    List<ShopAndGoodsInfoDto> getShopAndGoodsBySearch(String search, String longitude, String latitude, Long userId);
    List<StockGoodsDto> getStockGoodsByCategoryIdAndShopId(Long shopId, Long categoryId, Integer isAlive);
    List<GoodsInfoDto> getShopGoodsByShopIdAndCategoryId(Long shopId, Long categoryId);
    PageInfo<StockGoodsDto> getStockGoodsByCondition(ShopGoods shopGoods, Integer page, Integer size);
    //api
    Integer updateStockCount(Long shopId, Long specId, Integer goodsNum);
    Byte getGoodsStatus(Long shopId, Long specId);
    List<GoodsAndSpecInfoDto> getGoodsStatusList(List<GoodsAndSpecInfoDto> goodsAndSpecInfoDtos);
    Integer getLowPriceBySpecId(Long specId);
    List<GoodsAndSpecInfoDto> getShopGoodsSalePrice(ShopGoodsSalePriceDto shopGoodsSalePriceDto);
}
